package cn.zust.edu.cn;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public class ShapeManager {
	private List<IShape> shapes = new ArrayList<>();

	public List<IShape> getShapes() {
		return Collections.unmodifiableList(shapes);
	}

	public void addShape(IShape shape) {
		shapes.add(shape);
	}

	public void delShape(IShape shape) {
		shapes.remove(shape);
	}

	public void drawShapes() {
		for (IShape shape : shapes) {
			shape.draw();
			System.out.println();
		}
	}
}
